Skip to content

test(mcpx): probe the model settings through a prompt hook (#8473 chain 59) - #11898

Merged
dezren39 merged 1 commit into
mainfrom
test/mcpx-model-settings-probes
Nov 18, 2026
Merged

dezren39 merged 1 commit into
mainfrom
test/mcpx-model-settings-probes

Conversation

@dezren39

@dezren39 dezren39 commented Nov 18, 2026 •

Copy link
Copy Markdown
Member

Before: the model layer's settings were exempt from the #8473 effect guard because no settings-driven e2e reached a model.

After: a fake OpenAI-compatible endpoint (httptest) records what it is sent, and a local exec --json with one onSuccess prompt hook reaches it. Nine probes read the hook frame and the recorded request:

  • model.provider: none by default (hook reports no provider) vs openai (advice from the endpoint)
  • model.baseURL, model.providers: which of two endpoints answers
  • model.default, model.profiles: the model the request names
  • model.apiKeyEnv: no Authorization by default vs the named variable's value
  • model.budget, prompt.maxTokens: the request's max_tokens
  • model.timeout: a 700ms endpoint answers by default and is cut off at 100ms

EffectExemptionPin drops 61 → 52 (#8473 chain 59). sampling.answerLocally stays exempt; it's daemon-side.

How: fakeModel, promptHookFrame and the probes in internal/e2e/effect_test.go, registered in internal/settings/effect.go, exemption lines dropped. Test-only change.


Generated by Claude Code


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

A local exec whose config carries one onSuccess prompt hook talks to an
OpenAI-compatible httptest endpoint that records each request. That
gives with/without probes for model.provider, model.baseURL,
model.default, model.apiKeyEnv, model.budget, model.providers,
model.profiles, model.timeout and prompt.maxTokens, read from the hook
frame in `exec --json` and from what the endpoint was sent. Drops all
nine from the exemption list (EffectExemptionPin 61 -> 52, #8473
chain 59).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@dezren39
dezren39 marked this pull request as ready for review November 18, 2026 20:22
@dezren39
dezren39 requested a review from a team as a code owner November 18, 2026 20:22
@dezren39
dezren39 merged commit cbb6c06 into main Nov 18, 2026
@dezren39
dezren39 deleted the test/mcpx-model-settings-probes branch November 18, 2026 20:23
@coderabbitai

coderabbitai Bot commented Nov 18, 2026

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-18T20:24:10.026751Z d7d0946 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants